-
Notifications
You must be signed in to change notification settings - Fork 19
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: simulations format #114
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the great proposal!
I left some review comments, please check them out.
pkg/commands/commands_test.go
Outdated
if [ ${SIMULATIONS_FORMAT} = "bundle" ]; then | ||
gatling.sh -sf ${SIMULATIONS_DIR_PATH} -s ${SIMULATION_CLASS} -rsf ${RESOURCES_DIR_PATH} -rf ${RESULTS_DIR_PATH} -rm local | ||
elif [ ${SIMULATIONS_FORMAT} = "gradle" ]; then | ||
./gradlew -Dgatling.core.directory.results=${RESULTS_DIR_PATH} gatlingRun-${SIMULATION_CLASS} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is there a reason why you don't pass the simulations or resources directories as arguments?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
with Gatling Gradle Plugin, these files do have quite typical locations:
- simulations are under
src/gatling/java
orsrc/gatling/kotlin
orsrc/gatling/java
- resources are under
src/gatling/resources
I see that there's an option to customize these options via:
sourceSets {
gatling {
scala.srcDir "folder1" <1>
// or
scala.srcDirs = ["folder1"] <2>
resources.srcDir "folder2" <3>
// or
resources.srcDirs = ["folder2"] <4>
}
}
but I do not know upfront in which language the simulations were written, so it's quite hard to guess. IMHO convention over configuration rule applies here perfectly :)
@kane8n docs updated, comms addressed. Let me know please if there's anything pending :) |
@kkulak |
@kkulak |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm!
We'll have it ready for release this week.
@kkulak |
Description
Gatling scenarios can be defined in two ways at the moment:
simulationData
Furthermore, I'd like to make use of build tool, sth like that:
My proposal is to add a new property -
simulationsFormat
- which modifies the command being run bygatling-runner
- it only decides whether we should usegatling.sh
or gradle wrapper for the test execution. I've already checked the changed on my private EKS cluster, and they seem to work correctly, including features like S3 results upload.Tomorrow I'll add some examples and update docs. Let me know please @kane8n @gold-kou what are your thoughts. Cheers!
Checklist
Please check if applicable